"""
洗牌
"""
import random

list1 = [1,2,3,4,5]
list2 = []

while list1:
    index = random.randint(0,len(list1)-1)
    list2.append(list1.pop(index))

print(list2)